Skip to content

feat: implement GitHub OAuth login for User Dashboard#860

Merged
ayomideadeniran merged 1 commit into
StellarDevHub:mainfrom
khaylebfortune:feat/github-oauth-login-v2
Jul 1, 2026
Merged

feat: implement GitHub OAuth login for User Dashboard#860
ayomideadeniran merged 1 commit into
StellarDevHub:mainfrom
khaylebfortune:feat/github-oauth-login-v2

Conversation

@khaylebfortune

Copy link
Copy Markdown
Contributor

Implement complete GitHub OAuth login flow:

  • CSRF state management via OAuthState model with replay attack prevention
  • Authorization URL generation with read:user and user:email scope
  • OAuth callback with code exchange, GitHub API profile fetch
  • JWT-based session creation consistent with existing auth system
  • Account creation/linking: find by githubId, fallback to email, or create new
  • Frontend: Login page with GitHub button, callback page to handle redirect
  • Backend API: GET /github, GET/POST /github/callback, POST /github/link, GET /github/status
  • Validation schemas for OAuth callback and linking requests
  • Prisma migration adding githubId, githubUsername, githubAvatarUrl, githubAccessToken
  • OAuthState table for secure CSRF state management
  • Comprehensive test suite: unit tests, state management, API routes, account linking
  • CI/CD and Docker Compose updates with GitHub OAuth env vars

Closes #812

Implement complete GitHub OAuth login flow:
- CSRF state management via OAuthState model with replay attack prevention
- Authorization URL generation with read:user and user:email scope
- OAuth callback with code exchange, GitHub API profile fetch
- JWT-based session creation consistent with existing auth system
- Account creation/linking: find by githubId, fallback to email, or create new
- Frontend: Login page with GitHub button, callback page to handle redirect
- Backend API: GET /github, GET/POST /github/callback, POST /github/link, GET /github/status
- Validation schemas for OAuth callback and linking requests
- Prisma migration adding githubId, githubUsername, githubAvatarUrl, githubAccessToken
- OAuthState table for secure CSRF state management
- Comprehensive test suite: unit tests, state management, API routes, account linking
- CI/CD and Docker Compose updates with GitHub OAuth env vars

Closes StellarDevHub#812
@vercel

vercel Bot commented Jun 29, 2026

Copy link
Copy Markdown

@khaylebfortune is attempting to deploy a commit to the Ayomide Adeniran's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave

drips-wave Bot commented Jun 29, 2026

Copy link
Copy Markdown

@khaylebfortune Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@ayomideadeniran

Copy link
Copy Markdown
Contributor

PR under review and I will get back to you if I find any wrong implementations

@ayomideadeniran ayomideadeniran merged commit 95e8173 into StellarDevHub:main Jul 1, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[DevOps] Develop GitHub OAuth Login for User Dashboard

2 participants